from yield_from import gen
from PyCmpltrtok.common import sep

sep('next g')
g = gen()
print(next(g))
print(next(g))
print(next(g))
print(next(g))
# print(next(g))  # StopIteration
# print(next(g))  # StopIteration

sep('next gen()')
print(next(gen()))
print(next(gen()))
print(next(gen()))
